package ModelLayer;
import java.util.*;


/**
 * Write a description of class OrderLib here.
 * 
 * @author (your name) 
 * @version (a version number or a date)
 */
public class OrderLib
{
    // instance variables - replace the example below with your own
    private ArrayList<Order> orderLib;

    private static OrderLib instance;
    /**
     * Constructor for objects of class OrderLib
     */
    private OrderLib()
    {
        orderLib = new ArrayList<Order>();
    }
    
    public static OrderLib getOrderLib()
    {
        if(instance == null)
        {
            instance = new OrderLib();
        }
        
        return instance;
    }
    
    public void addOrder(Order order)
    {
        orderLib.add(order);
    }
    
    public int getOrderlistCount()
    {
        return orderLib.size();
    }
}
